package com.southwind.common;

import com.southwind.entity.Admin;
import com.southwind.entity.User;
import lombok.AllArgsConstructor;
import lombok.Data;

@Data
@AllArgsConstructor
public class ResultObj {

    public static final ResultObj LOGIN_SUCCESS = new ResultObj(0,"登录成功");
    public static final ResultObj LOGIN_ERROR_LOGINNAME = new ResultObj(-1,"用户名或类型错误");
    public static final ResultObj LOGIN_ERROR_PASSWORD = new ResultObj(-1,"密码错误");
    public static final ResultObj LOGIN_ERROR_CODE = new ResultObj(-1,"验证码错误");

    public static final ResultObj AREA_ADD_SUCCESS = new ResultObj(0,"区域添加成功");
    public static final ResultObj AREA_ADD_ERROR = new ResultObj(-1,"区域添加失败");

    public static final ResultObj BIKE_ADD_SUCCESS = new ResultObj(0,"单车添加成功");
    public static final ResultObj BIKE_ADD_ERROR = new ResultObj(-1,"单车添加失败");
    public static final ResultObj BIKE_NUMBER_ERROR = new ResultObj(-1,"添加失败，单车编号已存在");
    public static final ResultObj BIKE_UPDATE_SUCCESS = new ResultObj(0,"单车修改成功");
    public static final ResultObj BIKE_UPDATE_ERROR = new ResultObj(-1,"单车修改失败");
    public static final ResultObj BIKE_DELETEBATCH_SUCCESS = new ResultObj(0,"单车批量删除成功");
    public static final ResultObj BIKE_DELETEBATCH_ERROR = new ResultObj(-1,"单车批量删除失败");
    public static final ResultObj BIKE_DELETE_SUCCESS = new ResultObj(0,"单车删除成功");
    public static final ResultObj BIKE_DELETE_ERROR = new ResultObj(-1,"单车删除失败");

    public static final ResultObj DISPATCH_ADD_SUCCESS = new ResultObj(0,"调度添加成功");
    public static final ResultObj DISPATCH_ADD_ERROR = new ResultObj(-1,"调度添加失败");
    public static final ResultObj DISPATCH_UPDATE_SUCCESS = new ResultObj(0,"调度修改成功");
    public static final ResultObj DISPATCH_UPDATE_ERROR = new ResultObj(-1,"调度修改失败");
    public static final ResultObj DISPATCH_DELETEBATCH_SUCCESS = new ResultObj(0,"调度批量删除成功");
    public static final ResultObj DISPATCH_DELETEBATCH_ERROR = new ResultObj(-1,"调度批量删除失败");
    public static final ResultObj DISPATCH_DELETE_SUCCESS = new ResultObj(0,"调度删除成功");
    public static final ResultObj DISPATCH_DELETE_ERROR = new ResultObj(-1,"调度删除失败");

    public static final ResultObj FAULTH_ADD_SUCCESS = new ResultObj(0,"故障添加成功");
    public static final ResultObj FAULTH_ADD_ERROR = new ResultObj(-1,"故障添加失败");
    public static final ResultObj FAULTH_UPDATE_SUCCESS = new ResultObj(0,"故障修改成功");
    public static final ResultObj FAULTH_UPDATE_ERROR = new ResultObj(-1,"故障修改失败");
    public static final ResultObj FAULTH_DELETEBATCH_SUCCESS = new ResultObj(0,"故障批量删除成功");
    public static final ResultObj FAULTH_DELETEBATCH_ERROR = new ResultObj(-1,"故障批量删除失败");
    public static final ResultObj FAULTH_DELETE_SUCCESS = new ResultObj(0,"故障删除成功");
    public static final ResultObj FAULTH_DELETE_ERROR = new ResultObj(-1,"故障删除失败");

    public static final ResultObj APPEAL_ADD_SUCCESS = new ResultObj(0,"申诉请求成功");
    public static final ResultObj APPEAL_ADD_ERROR = new ResultObj(-1,"申诉请求失败");

    public static final ResultObj APPEAL_AUDITING_SUCCESS = new ResultObj(0,"申诉审核成功");
    public static final ResultObj APPEAL_AUDITING_ERROR = new ResultObj(-1,"申诉审核失败");

    public ResultObj(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    private Integer code;
    private String msg;
    private User user;
    private Admin admin;
    private Integer type;

}
